<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('调整会员余额')"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal m" id="form-member-balance-edit" th:object="${member}">
        <input name="id" type="hidden" th:field="*{id}"/>
        <div class="form-group">
            <label class="col-sm-3 control-label">当前余额：</label>
            <div class="col-sm-4">
                <input class="form-control" type="number" name="oldBalance" th:value="*{balance}" disabled>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label is-required">调整余额：</label>
            <div class="col-sm-4">
                <input class="form-control" id="balance" type="number" name="balance">
                <span class="help-block m-b-none"><i class="fa fa-info-circle"></i>正数为增加X元，负数为减少X元</span>
            </div>
        </div>
    </form>
</div>
<th:block th:include="include :: footer"/>

<script type="text/javascript">
    var prefix = ctx + "back/shopMember";

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/editBalance", $('#form-member-balance-edit').serialize());
        }
    }
</script>
</body>
</html>
